﻿<%@ Page Language="C#" AutoEventWireup="true" EnableViewState="false" CodeBehind="AttractionsInformation.aspx.cs"
    Inherits="NJL.Web.AttractionsInformation" %>

<%@ Import Namespace="Royalsoft.Common" %>
<%@ Register Src="Controls/WUCHeader.ascx" TagName="WUCHeader" TagPrefix="uc1" %>
<%@ Register Src="Controls/WUCFooter.ascx" TagName="WUCFooter" TagPrefix="uc2" %>
<%@ Register Src="Controls/WUCELPS.ascx" TagName="WUCELPS" TagPrefix="uc3" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title></title>
    <link rel="stylesheet" type="text/css" href="/Styles/base1.css" />
    <script type="text/javascript" language="javascript" src="/Scripts/jquery-1.4.1.min.js"></script>
    <script type="text/javascript" language="javascript" src="/Scripts/jquery.KinSlideshow-1.1.js"></script>
    <script src="/Scripts/popup_layer.js" type="text/javascript"></script>
    <script type="text/javascript">
        function GetValidate() {
            document.getElementById("Validate").src = "/ValidateCode.aspx?rand=" + Math.random();
        }
        $(document).ready(function () {
            getStartImage('gstart3');
        }
        );      
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <%
        if (UserId == "" || UserName == "")
        {         
    %>
    <script language="javascript" type="text/javascript">
        $(document).ready(function () {
            //示例9，综合效果
            var t9 = new PopupLayer({ trigger: "#txtComment", popupBlk: "#blk9", closeBtn: "#close9", useOverlay: true, useFx: true,
                offsets: {
                    x: 0,
                    y: -41
                }
            });
            t9.doEffects = function (way) {
                if (way == "open") {
                    this.popupLayer.css({ opacity: 0.3 }).show(400, function () {
                        this.popupLayer.animate({
                            left: ($(document).width() - this.popupLayer.width()) / 2,
                            top: (document.documentElement.clientHeight - this.popupLayer.height()) / 2 + $(document).scrollTop(),
                            opacity: 0.8
                        }, 1000, function () { this.popupLayer.css("opacity", 1) } .binding(this));
                    } .binding(this));
                    document.getElementById('Login').src = '<%=WEBSITE_USRE_DOMAIN %>/SecondLogin.aspx?websitecode=<%=WEBSITE_CODE %>&domain=<%=WEBSITE_DOMAIN %>&url=<%=Request.RawUrl %>';
                }
                else {
                    this.popupLayer.animate({
                        left: this.trigger.offset().left,
                        top: this.trigger.offset().top,
                        opacity: 0.1
                    }, { duration: 500, complete: function () { this.popupLayer.css("opacity", 1); this.popupLayer.hide() } .binding(this) });
                }
            }
            var dingpiao = new PopupLayer({ trigger: "#opendingpiao", popupBlk: "#blk9dingpiao", closeBtn: "#close9dingpiao", useOverlay: true, useFx: true,
                offsets: {
                    x: 0,
                    y: -41
                }
            });
            dingpiao.doEffects = function (way) {
                if (way == "open") {
                    this.popupLayer.css({ opacity: 0.3 }).show(400, function () {
                        this.popupLayer.animate({
                            left: ($(document).width() - this.popupLayer.width()) / 2,
                            top: (document.documentElement.clientHeight - this.popupLayer.height()) / 2 + $(document).scrollTop(),
                            opacity: 0.8
                        }, 1000, function () { this.popupLayer.css("opacity", 1) } .binding(this));
                    } .binding(this));
                    document.getElementById('Logindingpiao').src = '<%=WEBSITE_USRE_DOMAIN %>/SecondLogin.aspx?websitecode=<%=WEBSITE_CODE %>&domain=<%=WEBSITE_DOMAIN %>&url=<%=Request.RawUrl %>';
                }
                else {
                    this.popupLayer.animate({
                        left: this.trigger.offset().left,
                        top: this.trigger.offset().top,
                        opacity: 0.1
                    }, { duration: 500, complete: function () { this.popupLayer.css("opacity", 1); this.popupLayer.hide() } .binding(this) });
                }
            }
        });
    </script>
    <div id="blk9" class="blk">
        <div class="popup_title">
            <span class="f_right"><a href="javascript:void(0)" id="close9">关闭</a></span>
            <ul>
                <li class="now"><a target="main">登录</a> </li>
            </ul>
        </div>
        <div>
            <iframe id="Login" name="main" width="500" height="420" style="overflow: hidden;
                border: none;" frameborder="no" border="0"></iframe>
        </div>
    </div>
    <div id="blk9dingpiao" class="blk">
        <div class="popup_title">
            <span class="f_right"><a href="javascript:void(0)" id="close9dingpiao">关闭</a></span>
            <ul>
                <li class="now"><a target="main">登录</a> </li>
            </ul>
        </div>
        <div>
            <iframe id="Logindingpiao" name="main" width="500" height="420" style="overflow: hidden;
                border: none;" frameborder="no" border="0"></iframe>
        </div>
    </div>
    <%
        }
    %>
    <uc1:WUCHeader ID="WUCHeader1" runat="server" />
    <!--主要内容-->
    <div class="clearfix w1003" id="content">
        <!--顶部推广-->
        <div class="blank cleanFlex">
        </div>
        <div>
            <!--旅游景点-->
            <div class="f_left" style="overflow: hidden; width: 670px;">
                <!--位置-->
                <div class="place02">
                    <p>
                        您现在的位置是：<a href="/">首页</a>>><span><a href="<%if(WEBSITE_FOCUS_CITY_CODE!="") Response.Write("/"+WEBSITE_FOCUS_CITY_NAME_PINYIN); %>/jdms/">景点名胜</a></span>>><span><%=MODEL.ATTRACTION_NAME%></span>
                    </p>
                </div>
                <!--特产-->
                <div class="localgoods m_top_10">
                    <!--图片-->
                    <div class="goodspic f_left">
                        <img src="<%=(MODEL.IMAGE_CODE!=null && MODEL.IMAGE_CODE!="")?GetImageUrl(MODEL.IMAGE_CODE,"C1"):"/Images/nopic.jpg" %>"
                            alt="" class="picBor" width="269px" />
                    </div>
                    <!--特产信息-->
                    <div style="width: 380px;" class="goodsInfo f_right">
                        <h3>
                            <strong class="font14">
                                <%=MODEL.ATTRACTION_NAME%></strong></h3>
                        <p class="m_top_5">
                            <strong>详细地址：</strong><span class="grayfont"><%=MODEL.ATTRACTION_ADDRESS%></span></p>
                        <p class="m_top_5">
                            <strong>发布时间：</strong><span class="grayfont"><%=Convert.ToDateTime(MODEL.PUBLISH_DATE_TIME).ToString("yyyy-MM-dd HH:mm:ss")%></span></p>
                        <p class="m_top_5">
                            网友点评<span class="orange04"><asp:Literal ID="litCommentCount" runat="server"></asp:Literal></span>条&nbsp;&nbsp;<span
                                class="greenlink"><a href="#comment">查看点评</a></span></p>
                    </div>
                    <%
                        if (LIST_BOOK.Count > 0)
                        {
                    %>
                    <!--打折门票-->
                    <div class="cleanFlex blank">
                    </div>
                    <div>
                        <div class="titleTab02">
                            <ul>
                                <li class="now"><a>打折门票</a></li>
                            </ul>
                        </div>
                        <div>
                            <div class="blank">
                            </div>
                            <table width="100%" border='0' cellspacing='0' cellpadding='0' class="tabBord">
                                <tr>
                                    <th scope='col'>
                                        门票类型
                                    </th>
                                    <th scope='col'>
                                        票面价
                                    </th>
                                    <th scope='col'>
                                        本站价
                                    </th>
                                    <th scope='col'>
                                        点评奖金
                                    </th>
                                    <th scope='col'>
                                        为您节省
                                    </th>
                                    <th scope='col'>
                                        支付方式
                                    </th>
                                    <th scope='col'>
                                        操作
                                    </th>
                                </tr>
                                <%
                                    for (int i = 0; i < LIST_BOOK.Count; i++)
                                    {
                                %>
                                <tr>
                                    <td style='color: #195cb5;'>
                                        <a href='/AttractionsOrder.aspx?id=<%=Request.QueryString["id"] %>&bid=<%=LIST_BOOK[i].ID %>'
                                            style='color: #195CB5' title='<%=LIST_BOOK[i].BOOK_NAME %>' target="_blank">
                                            <%=LIST_BOOK[i].BOOK_NAME %></a>
                                    </td>
                                    <td>
                                        <del style='color: #ff6600'><span style='color: #333'>¥<%=LIST_BOOK[i].MARKET_PRICE.Value.ToString("#") %></span></del>
                                    </td>
                                    <td class='font_2'>
                                        ¥<%=LIST_BOOK[i].LOCAL_PRICE.Value.ToString("#")%>
                                    </td>
                                    <td class='font_2'>
                                        ¥<%=LIST_BOOK[i].BACK_PRICE.Value.ToString("#")%>
                                    </td>
                                    <td class='font_2'>
                                        ¥<%=(LIST_BOOK[i].MARKET_PRICE - LIST_BOOK[i].LOCAL_PRICE + LIST_BOOK[i].BACK_PRICE).Value.ToString("#")%>
                                    </td>
                                    <td>
                                        <%=GetBookPayType(LIST_BOOK[i].NJL_CS_BOOK_PAY_TYPE_CODE)%>
                                    </td>
                                    <td>
                                        <a  href="/AttractionsOrder.aspx?id=<%=Request.QueryString["id"]%>&bid=<%= LIST_BOOK[i].ID%>" target='_blank'>
                                            <img src='/Images/yuding.gif' alt="预定" /></a>
                                    </td>
                                </tr>
                                <%
                                    }
                                %>
                            </table>
                        </div>
                    </div>
                    <% 
                        }
                    %>
                    <!--特产信详情-->
                    <div class="cleanFlex blank">
                    </div>
                    <div>
                        <div class="titleTab02">
                            <ul>
                                <li class="now"><a>景点介绍</a></li>
                                <%--  <li><a href="#">全部点评</a></li>--%>
                            </ul>
                        </div>
                        <div class="newscont font14 m_top_10">
                            <p>
                                <%=MODEL.TICKET_NOTICE %></p>
                        </div>
                        <div style="margin: 10px auto; width: 300px;">
                            <!-- JiaThis Button BEGIN -->
                            <div id="jiathis_style_32x32">
                                <a class="jiathis_button_qzone"></a><a class="jiathis_button_tsina"></a><a class="jiathis_button_tqq">
                                </a><a class="jiathis_button_renren"></a><a class="jiathis_button_kaixin001"></a>
                                <a href="http://www.jiathis.com/share/" class="jiathis jiathis_txt jtico jtico_jiathis"
                                    target="_blank"></a><a class="jiathis_counter_style"></a>
                            </div>
                            <script type="text/javascript" src="http://v2.jiathis.com/code/jia.js" charset="utf-8"></script>
                            <!-- JiaThis Button END -->
                        </div>
                    </div>
                    <div class="cleanFlex">
                    </div>
                    <div class="m_top_20">
                        <div class="newscont m_top_10">
                            <asp:Repeater ID="rptCommentList" runat="server" OnItemDataBound="rptCommentList_ItemDataBound">
                                <ItemTemplate>
                                    <dl class="imglist cleanFlex" style="min-height: 62px; height: 100%;">
                                        <dt><a href="/wanjia/<%#Eval("CREATE_USER_ID") %>-index.html" target="_blank">
                                            <asp:Image ID="imgUserHead" runat="server" Width="67" Height="50" BorderWidth="1"
                                                CssClass="picBor"></asp:Image></a></dt>
                                        <dd class="f_right">
                                            评分：
                                            <asp:Literal ID="litStartSum" runat="server"></asp:Literal>
                                        </dd>
                                        <dd>
                                            <strong><a href="/wanjia/<%#Eval("CREATE_USER_ID") %>-index.html" target="_blank">
                                                <%#Eval("CREATE_USER_NAME")%></a></strong>
                                            <%#Eval("CREATE_DATE_TIME")%>
                                        </dd>
                                        <dd class="m_top_10">
                                            <%#Eval("COMMENT_CONTENT")%></dd>
                                    </dl>
                                </ItemTemplate>
                            </asp:Repeater>
                        </div>
                        <!--评论-->
                        <div class="m_top_20 cleanFlex comment">
                            <div class="cont">
                                <p>
                                    <a name="comment"></a><strong>总体印象：</strong>
                                    <%
                                        for (int i = 1; i <= 5; i++)
                                        {
                                    %>
                                    <img src="/Images/half_start.jpg" alt="<%=i %>" id="gstart<%=i %>" onclick="getStartImage('gstart<%=i %>')"
                                        style="cursor: pointer" />
                                    <%
                                        }
                                    %>
                                    &nbsp;<span class="grayfont">请点击星给此景点评分</span>
                                </p>
                                <p>
                                    <strong>我的评论：</strong>
                                </p>
                                <p>
                                    <asp:TextBox ID="txtComment" runat="server" Height="50px" TextMode="MultiLine" class="input"
                                        Width="650px"></asp:TextBox>
                                </p>
                                <p>
                                    <span class="f_right">
                                        <asp:Button ID="btnComment" runat="server" class="postbtn" OnClientClick="return check()"
                                            OnClick="btnComment_Click" />
                                    </span>验证码：<asp:TextBox ID="txtValidate" runat="server" class="input" Width="60px"
                                        onblur="validateCode()" MaxLength="4"></asp:TextBox>&nbsp;&nbsp;<img id="Validate"
                                            src="/ValidateCode.aspx" onclick="javascript:GetValidate()" alt="验证码" title="看不清，点击图片，换一张"
                                            align="absmiddle" width="56px" height="20px" style="cursor: pointer" /></p>
                            </div>
                        </div>
                    </div>
                </div>
                <div id="tag" runat="server" class="m_top_10 boxgray">
                    <div class="titleGreen">
                        <h3>
                            <strong>热门标签</strong></h3>
                    </div>
                    <div class="cont">
                        <p>
                            <% 
                                System.Random random = new Random();
                                for (int i = 0; i < LIST_TAG.Count; i++)
                                {
                                    int iRandom = random.Next(0, 9);
                            %>
                            <a target="_blank" href="/SearchAttractions.aspx?keywords=<%=Server.UrlEncode(LIST_TAG[i].TAG) %>&cc=<%=WEBSITE_FOCUS_CITY_NAME_PINYIN%>"
                                class="tag<%=iRandom.ToString() %>">
                                <%=LIST_TAG[i].TAG%>
                            </a>
                            <%
}
                            %>
                        </p>
                    </div>
                </div>
                <div class="blank dashline cleanFlex">
                </div>
                <!--相关新闻-->
                <div class="cleanFlex">
                </div>
                <div class="m_top_10 boxgray">
                    <div class="titleGreen">
                        <h3>
                            <strong>相关新闻</strong></h3>
                    </div>
                    <div class="cont">
                        <div class="f_left" style="width: 100%;">
                            <ul class="arrowList02">
                                <%
                                    for (int i = 0; i < LIST_SYS_NEWS.Count; i++)
                                    {
                                %>
                                <li><span>[<%=LIST_SYS_NEWS[i].PUBLISH_DATE_TIME.Value.ToString("yyyy-MM-dd HH:mm:ss")%>]</span>
                                    <a target="_blank" title="<%=LIST_SYS_NEWS[i].NEWS_TITLE %>" href="/xckb/<%=LIST_SYS_NEWS[i].TYPE_CODE %>/<%=LIST_SYS_NEWS[i].ID %>.html">
                                        <%if (LIST_SYS_NEWS[i].NEWS_TITLE.Length > 32) Response.Write(LIST_SYS_NEWS[i].NEWS_TITLE.Substring(0, 32) + "..."); else Response.Write(LIST_SYS_NEWS[i].NEWS_TITLE); %></a></li>
                                <% 
                                    }
                                %>
                            </ul>
                        </div>
                    </div>
                    <div class="cleanFlex">
                    </div>
                </div>
                <!--美食推荐-->
                <div class="cleanFlex blank" style="display: none">
                </div>
                <div class="cleanFlex boxgray" style="display: none">
                    <div class="titleGreen">
                        <span class="f_right"><a href="#">更多</a></span>
                        <h3>
                            <strong>美食分享</strong></h3>
                    </div>
                    <div class="cont cleanFlex">
                        <ul class="imglist imglistF">
                            <li><a href="#">
                                <img src="Images/ads_47.jpg" alt="" class="picBor" /></a><p>
                                    <a href="#">农家小炒肉</a></p>
                            </li>
                            <li><a href="#">
                                <img src="Images/ads_47.jpg" alt="" class="picBor" /></a><p>
                                    <a href="#">农家小炒肉</a></p>
                            </li>
                            <li><a href="#">
                                <img src="Images/ads_47.jpg" alt="" class="picBor" /></a><p>
                                    <a href="#">农家小炒肉</a></p>
                            </li>
                            <li><a href="#">
                                <img src="Images/ads_47.jpg" alt="" class="picBor" /></a><p>
                                    <a href="#">农家小炒肉</a></p>
                            </li>
                        </ul>
                    </div>
                    <div class="cleanFlex">
                    </div>
                </div>
            </div>
            <!--右侧-->
            <div class="f_right" style="width: 316px; overflow: hidden;">
                <uc3:WUCELPS ID="WUCELPS1" runat="server" />
                <div class="blank cleanFlex">
                </div>
            </div>
        </div>
        <div class="blank cleanFlex">
        </div>
    </div>
    <uc2:WUCFooter ID="WUCFooter1" runat="server" />
    <asp:HiddenField ID="hidScore" runat="server" />
    <script type="text/javascript">

        function check() {
            var txtComment = document.getElementById("<%=txtComment.ClientID %>").value;
            var txtValidate = document.getElementById("<%=txtValidate.ClientID %>").value;
            txtComment = $.trim(txtComment);
            if (txtComment == "") {
                alert("评论内容不能为空哦^_^");
                return false;
            }
            if (txtComment.length > 100) {
                alert("评论内容字数不能超过100个哦^_^");
                return false;
            }
            txtValidate = $.trim(txtValidate);
            if (txtValidate == "") {
                alert("验证码不能为空哦^_^");
                return false;
            }
            if (document.getElementById("Hidden1").value == 1) {
                alert("请输入正确的验证码");
                return false;
            }
        }
        function validateCode() {
            var txtValidate = document.getElementById("<%=txtValidate.ClientID %>").value;
            var isTure = true;
            $.ajax({
                type: 'get',
                url: '/Handle/Handler.ashx',
                data: { validateCode: '' + txtValidate, random: Math.round() },
                dataType: 'text',
                success: function (msg) {
                    if (msg == "False") {
                        document.getElementById("Hidden1").value = 1;
                    }
                    else {
                        document.getElementById("Hidden1").value = 0;
                    }
                },
                error: function () {
                }
            })
        }
        function getStartImage(id) {
            var imgid = id.replace("gstart", "");
            for (var i = 1; i <= 5; i++) {
                document.getElementById('gstart' + i).src = "/Images/half_start.jpg";
            }
            for (var j = 1; j <= imgid; j++)
                document.getElementById('gstart' + j).src = "/Images/start.jpg";
            document.getElementById("<%=hidScore.ClientID %>").value = imgid;
        }     
    </script>
    </form>
    <input id="Hidden1" type="hidden" />
</body>
</html>
